﻿@** Copyright 2013 Seven Spikes Ltd. All rights reserved. (http://www.nop-templates.com)
* http://www.nop-templates.com/t/licensinginfo
*@

@using Nop.Web.Models.ShoppingCart
@model Nop.Web.Models.ShoppingCart.MiniShoppingCartModel
@{
    var shoppingCartItemModel = Model.Items[0];
}
<div class="productAddedToCartWindow">
    <div class="productAddedToCartWindowTitle">
        @T("SevenSpikes.NopAjaxCart.ShoppingCartNotificationBoxTitle")
    </div>
    <div class="productAddedToCartWindowImage">
        <a href="@Url.RouteUrl("Product", new { SeName = shoppingCartItemModel.ProductSeName })" title="@shoppingCartItemModel.Picture.Title">
            <img alt="@shoppingCartItemModel.Picture.AlternateText" src="@shoppingCartItemModel.Picture.ImageUrl" title="@shoppingCartItemModel.Picture.Title" />
        </a>
    </div>
    <div class="productAddedToCartWindowDescription">
        <h1>
            <a href="@Url.RouteUrl("Product", new { SeName = shoppingCartItemModel.ProductSeName })">@shoppingCartItemModel.ProductName</a>
        </h1>
        <strong class="price">@shoppingCartItemModel.UnitPrice</strong>
        <span class="quantity">@T("SevenSpikes.NopAjaxCart.ShoppingCartNotificationBoxQuantity") : @shoppingCartItemModel.Quantity</span>
    </div>
    <div class="productAddedToCartWindowSummary">
        <a class="continueShoppingLink" href="" onclick="nopAjaxCart.closeProductAddedToCartWindow(); return false;">@T("SevenSpikes.NopAjaxCart.ShoppingCartNotificationBoxContinueShopping")</a>
        @if (Model.DisplayCheckoutButton)
        {
            var checkoutUrl = "";
            if (Model.AnonymousCheckoutAllowed && Model.CurrentCustomerIsGuest)
            {
                checkoutUrl = Url.RouteUrl("LoginCheckoutAsGuest", new { returnUrl = Url.RouteUrl("ShoppingCart") });
            }
            else
            {
                checkoutUrl = Url.RouteUrl("Checkout");
            }
            <a class="viewBasketLink" href="@Url.RouteUrl("ShoppingCart")">@T("SevenSpikes.NopAjaxCart.ShoppingCartNotificationBoxViewYourBasket")</a>
            <div>
                <input type="submit" class="button-1 productAddedToCartWindowCheckout" value="@T("Checkout.Button")" onclick="setLocation('@checkoutUrl');" />
            </div>
        }
        else
        {
            <div>
                <input type="submit" class="button-1 productAddedToCartWindowCheckout" value="@T("ShoppingCart.Mini.ViewCart")" onclick="setLocation('@Url.RouteUrl("ShoppingCart")');" />
            </div>
        }
    </div>
</div>
